package com.xja.zufang.service.impl;

import com.xja.zufang.entity.Users;
import com.xja.zufang.mapper.UsersMapper;
import com.xja.zufang.service.Userservice;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service("userService")
public class UserServiceImpl implements Userservice {
  @Autowired
    private UsersMapper usersMapper;


    @Override
    public Users selectLogin(String name) throws Exception {
        return usersMapper.selectLogin(name);
    }

  @Override
  public boolean addreg(Users r) {
    return  usersMapper.insert(r)>0;
  }
}
